﻿@{
    Layout = "~/_SiteLayout.cshtml";
    string rootid = new Business.Platform.Dictionary().GetIDByCode("FlowTypes").ToString();
}

    <form id="form1" runat="server">
        <div id="tree"></div>
    </form>
    <script type="text/javascript">
        var AppID = '@Request.QueryString["appid"]';
        var tabid = '@Request.QueryString["tabid"]';
        var roadTree = null;
        $(function ()
        {
            roadTree = new RoadUI.Tree({ id: "tree", path: "/Platform/Dict/Tree1?root=@rootid", refreshpath: "/Platform/Dict/TreeRefresh", onclick: openUrl });
        });
        function openUrl(json)
        {
            parent.frames[1].location = "InstanceList?typeid=" + json.id + "&appid=" + AppID + "&tabid=" + tabid;
        }
        function reLoad(id)
        {
            roadTree.refresh(id);
        }
    </script>